You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This work is underway, and function and input names are all subject to potentially change until merged into devel. But as this also seems to be a major hole in the field, anyone wishing to use/test these functionality early can install from this branch with remotes::install_github("dtm2451/dittoSeq@neighbor-diversity"), then restart your R if you'd already had dittoSeq loaded.
One thing to note, and I'll aim to work this into the documentation, is that the algorithm I'm basing the calcNeighborMetadataDiversity() calculation off of made use of a NearestNeighbors calculation run specifically for this purpose that used k=sqrt(ncells). This number of neighbors may be overkill for gigantic datasets, but the important thing is that using only the 20-or-so neighbors regularly recorded after a "standard" Seurat algorithm run 1) cannot yield quite as accurate of results, and 2) negates some of the utility of using a quantile cutoff on neighbor distances due to the relative inflation of such distances.
So:
adjust documentation to recommend running neighbors calculation with higher number of neighbors retained
adjust defaulting to 1) warn and 2) not use the distance quantile trimming unless the number of neighbors in neighbors is at least 30.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR adds a new functionality and plotters to go with it:
Motivation: Plotting such data can be VERY useful for batch effect assessment
The goal is to create 3 primary functions:
calcNeighborMetadataDiversity(): to perform the diversity calculationsdittoNeighborDiversityPlot(): to automate plotting these data usingdittoDimPlot()dittoNeighborDiversityHex(): to automate plotting these data usingdittoDimHex()Steps:
calcNeighborMetadataDiversity()dittoNeighborDiversityPlot().default_neighbors()for backend (auto-determination of Neighbors-data to use within the user giving it)dittoNeighborDiversityHex()